package com.uls.questionnaire.domain;

import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.uls.common.annotation.Excel;
import com.uls.common.core.domain.BaseEntity;

/**
 * 存储回答信息的对象 zxh_response
 * 
 * @author zxh
 * @date 2024-11-17
 */
public class Response extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 回答id */
    private Long responseId;

    /** 问卷表id */
    @Excel(name = "问卷表id")
    private Long questionnaireId;

    /** 存储回答的数据 */
    @Excel(name = "存储回答的数据")
    private String responseData;

    /** 回答时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "回答时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date responseTime;

    /** 是否匿名参与 */
    @Excel(name = "是否匿名参与")
    private Integer isanonymous;

    /** 回答人 */
    @Excel(name = "回答人")
    private String responseBy;

    /** 问题id */
    @Excel(name = "问题id")
    private Long questionId;

    public void setResponseId(Long responseId) 
    {
        this.responseId = responseId;
    }

    public Long getResponseId() 
    {
        return responseId;
    }
    public void setQuestionnaireId(Long questionnaireId) 
    {
        this.questionnaireId = questionnaireId;
    }

    public Long getQuestionnaireId() 
    {
        return questionnaireId;
    }
    public void setResponseData(String responseData) 
    {
        this.responseData = responseData;
    }

    public String getResponseData() 
    {
        return responseData;
    }
    public void setResponseTime(Date responseTime) 
    {
        this.responseTime = responseTime;
    }

    public Date getResponseTime() 
    {
        return responseTime;
    }
    public void setIsanonymous(Integer isanonymous) 
    {
        this.isanonymous = isanonymous;
    }

    public Integer getIsanonymous() 
    {
        return isanonymous;
    }
    public void setResponseBy(String responseBy) 
    {
        this.responseBy = responseBy;
    }

    public String getResponseBy() 
    {
        return responseBy;
    }
    public void setQuestionId(Long questionId) 
    {
        this.questionId = questionId;
    }

    public Long getQuestionId() 
    {
        return questionId;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("responseId", getResponseId())
            .append("questionnaireId", getQuestionnaireId())
            .append("responseData", getResponseData())
            .append("responseTime", getResponseTime())
            .append("isanonymous", getIsanonymous())
            .append("responseBy", getResponseBy())
            .append("questionId", getQuestionId())
            .toString();
    }
}
